cmake_minimum_required(VERSION 3.2) 
set(Pj_name LinemodDetectorTool)
set(home /home/de/testCode/tensorflowVision)
## 使用ORK的渲染工具
FIND_PACKAGE(object_recognition_renderer REQUIRED)
FIND_PACKAGE(PCL REQUIRED)

INCLUDE_DIRECTORIES(${Pj_name} 
    ${object_recognition_renderer_INCLUDE_DIRS}
    /opt/ros/kinetic/include/opencv-3.3.1-dev 
    ${home}/linemod_before 
    ${PCL_INCLUDE_DIRS} 
    .
    ${home}/PclDepthToCloud  ## PCL VISUAL
    ${home}/CsvData/CsvData
    )

link_directories(${Pj_name} 
    ${PCL_LIBRARY}
    /opt/ros/kinetic/lib/x86_64-linux-gnu
   ${home}/CsvData/build
    )
    
# ADD_LIBRARY(${Pj_name} SHARED linemod_detector_Tool.cpp)
add_executable(${Pj_name} linemod_detector_Tool.cpp test.cpp  ${home}/PclDepthToCloud/PclViewTools.cpp)
add_definitions(-std=c++11)

TARGET_LINK_LIBRARIES(${Pj_name}
    ${object_recognition_renderer_LIBRARIES}
    ${opencv_candidate_LIBRARIES}
    -lopencv_imgcodecs3 -lopencv_imgproc3 -lopencv_core3 -lopencv_highgui3 -lopencv_rgbd3 
    -lpcl_visualization -lboost_system -lpcl_io -lboost_thread
    -lvtkRenderingFreeTypeOpenGL-6.2 -lvtkRenderingMatplotlib-6.2 -lvtkRenderingFreeTypeFontConfig-6.2 -lvtkInteractionStyle-6.2 
    -lvtkRenderingOpenGL-6.2 -lvtkRenderingFreeType-6.2 -lvtkCommonCore-6.2 -lpcl_common -lvtkRenderingLOD-6.2 -lvtkRenderingCore-6.2
    -lvtkFiltersSources-6.2 -lvtkCommonExecutionModel-6.2 -lvtkCommonDataModel-6.2 -lvtkCommonMath-6.2
    -lCsvData
    )

INSTALL(TARGETS ${Pj_name} DESTINATION lib)
